namespace Expect.Core
{
    /// <summary>
    /// Define the service contract for transforming name elements such as converting the input to a property name or method name
    /// </summary>
    public interface INameProvider
    {
        /// <summary>
        /// Transform a string by making it compliant to a code name. For example, removing accents or spaces
        /// </summary>
        /// <param name="input">the input string</param>
        /// <returns>conformed string</returns>
        string ConformString(string input);

        /// <summary>
        /// Build an element name by concatenation of the strings and appliance of PascalCase
        /// </summary>
        /// <param name="inputs">the list of strings input</param>
        /// <returns></returns>
        string ElementName(params string[] inputs);

        /// <summary>
        /// Indicate if the input string is a method. For example fit's method name end with "()" or "?"
        /// </summary>
        /// <param name="input"></param>
        /// <returns></returns>
        bool IsAMethod(string input);
        
        /// <summary>
        /// Remove the method identifier of the input. ConformString may call this method...
        /// </summary>
        /// <param name="input"></param>
        /// <returns></returns>
        string RemoveMethodIdentifier(string input);
        
        /// <summary>
        /// Indicate if the input could be considered as a keyword of the provided type. 
        /// This method help translating keywords or at least flexibility about the keywords in fixtures like ActionFixture
        /// </summary>
        /// <param name="keyword">the keyword "type" or root definition</param>
        /// <param name="input">the input string</param>
        /// <returns>true if the input match the keyword</returns>
        bool IsAKeywordFor(string keyword, string input);
    }
}